#pragma once

#include <QTableView>
#include "plotdata.h"
#include "plotmodel.h"
/**
* ��ʾ�������ߵ�List
*/
class PlotTableView  : public	QTableView
{
	Q_OBJECT

public:
	PlotTableView(QSharedPointer<PlotModel>,QWidget*parent);
	~PlotTableView();
	auto getModel()const{return _model;};
public slots:
	void add_plotData(QSharedPointer<QCPGraphDataContainer>& data, QString plot_name = "name");
	void setCurrPlotData(const QSharedPointer<PlotData>& );
	void setPlotStatus(const int64_t uuid, bool status);
private:
	void _InitConnect();
	void selectionChanged(const QItemSelection& selected,
	const QItemSelection& deselected) override;
private:
	QSharedPointer<PlotModel> _model;
};
